#cmake_minimum_required(VERSION 3.0.2)
#project(send)
#if (DEPLOYMENT)
#
#endif ()
#
#find_package(Threads REQUIRED)
#
#include_directories(
#        include
#        ${catkin_INCLUDE_DIRS}
#        ${OpenCV_INCLUDE_DIRS}
#        ${Boost_INCLUDE_DIRS}
#        ${EiGEN3_INCLUDE_DIRS}
#)
#
#add_executable(${PROJECT_NAME} src/main.cpp
#                    src/tedataDJ.cpp
#                    src/udp.cpp
#                    src/generateData.cpp
#)
#
#target_link_libraries(${PROJECT_NAME}
#        ${Boost_LIBRARIES}
#        ${OpenCV_LIBS}
#        Threads::Threads)


cmake_minimum_required(VERSION 3.0.2)
project(send)

set(CMAKE_CXX_STANDARD 14)

include_directories(
        include
)

# 公共源文件
set(SOURCES
        src/udp.cpp
        src/generateData.cpp
        src/tedataDJ.cpp
        src/parseData.cpp
)

# 客户端
add_executable(client
        src/client_main.cpp
        ${SOURCES}
)

# 服务端
add_executable(server
        src/server_main.cpp
        ${SOURCES}
)

# 链接系统库（如 pthread 等）
find_package(Threads REQUIRED)
target_link_libraries(client Threads::Threads)
target_link_libraries(server Threads::Threads)
